#!/usr/bin/python3
# coding: utf-8
# base_views.py
# 2018-07-13
from flask import jsonify, make_response
from app.ext import auth
from app import app


@app.errorhandler(404)
def page_not_found(e):
	return make_response(jsonify({'status': 'error', 'msg': 'Not found'}), 404)

@app.errorhandler(400)  
def page_not_found(e):
	return make_response(jsonify({'status': 'error', 'msg': 'Bad Request'}), 400)

@auth.error_handler
def unauthorized():
	return make_response(jsonify({'error': 'Unauthorized access'}), 403)

@app.route('/')
# @auth.login_required
def index():
	return "<h1>Hello Weclome Python Api System!<h1>"

